You are here: Trading System Programming > Reference > Classes > Order > Order Methods > getLimitPrice

getLimitPrice

The getLimitPrice method returns order's limit price.

Syntax

var getLimitPrice();

Return Value

This method returns limit price as a floating value.

Example

The following example demonstrates the use of getLimitPrice() method.

 

function start()

{

//retrieve account's open orders

var account = getAccount();

var openOrders = account.getOrders();

 

//loop through all orders

for(var i = 0; i < openOrders.length, i++)

{

var order = openOrders[i];

 

if(order.getOrderType() == ORDERTYPE_LIMIT)

{

//get limit Price

var limitPrice = order.getLimitPrice();

}

}

 

//proceed further...

}

 


Copyright © 2006-2009 ActiveTick LLC